<template>
  <iframe :src="props.src" :style="{ width: computedWidth, height: computedHeight }" frameborder="0"></iframe>
</template>

<script setup lang="ts">
import { computed, defineProps } from 'vue';

interface Props {
  src: string;
  width: string;
  height: string;
}

const props = defineProps<Props>();

const computedWidth = computed(() => `${props.width}`);
const computedHeight = computed(() => `${props.height}`);
</script>

<style scoped>
/* 样式可根据需要调整 */
iframe {
  border: none;
}
</style>